//
//  BalanceVC.m
//  QoilPublic
//
//  Created by SunChao on 2018/2/1.
//  Copyright © 2018年 孙超. All rights reserved.
//

#import "BalanceVC.h"
#import "QTopupMoneyVC.h"
#import "MoneyDetailVC.h"
@interface BalanceVC ()
@property (weak, nonatomic) IBOutlet UIImageView *bgImageView;
@property (weak, nonatomic) IBOutlet UILabel *moneyLabel;
@property (weak, nonatomic) IBOutlet UIButton *addMoneyBtn;
@property (weak, nonatomic) IBOutlet UIButton *moneyDetailBtn;

@end

@implementation BalanceVC


- (void)viewDidLoad {
    
    [super viewDidLoad];
    
    self.title = @"个人余额";
    
    self.bgImageView.layer.cornerRadius = 10.0f;
    self.bgImageView.layer.masksToBounds = YES;
    self.bgImageView.contentMode = UIViewContentModeScaleAspectFit;
    self.addMoneyBtn.layer.cornerRadius = 5.0f;
    self.addMoneyBtn.layer.masksToBounds = YES;
    self.moneyDetailBtn.layer.cornerRadius = 5.0f;
    self.moneyDetailBtn.layer.masksToBounds = YES;
    self.moneyLabel.text = [NSString stringWithFormat:@"%@",[QUserInfo sharedInfo].loginModel.balance];

}

- (void)back{
    
    [self.navigationController popViewControllerAnimated:YES];
    
}



#pragma mark 点击充值方法
- (IBAction)addMoneyAction:(UIButton *)sender {
    
    QTopupMoneyVC *vc = [[QTopupMoneyVC alloc] init];
    [self.navigationController pushViewController:vc animated:YES];
    
}

#pragma mark 点击交易详情
- (IBAction)moneyDetailAction:(UIButton *)sender {

    MoneyDetailVC *vc = [[MoneyDetailVC alloc]init];
    [self.navigationController pushViewController:vc animated:YES];

}
@end
